import './assets/main.scss'
import { createApp } from 'vue'
import { createPinia } from 'pinia'
import piniaPluginPersistedstate from 'pinia-plugin-persistedstate';
import axios from "axios";

import App from './App.vue'
import router from './router'

// import setupPermission from "@/plugins";

import scu4 from "@/views/day20241212/stu.vue";
import { h } from "vue";

const app = createApp(App)

const pinia=createPinia()
pinia.use(piniaPluginPersistedstate)

// app.component('scu4',scu4)
app.component('MyComponent3',{
    name:'MyComponent3',
    render():unknown{
        return h('div',[
            h('h1','通过vue的h函数自定义渲染'),
            h('p','This content is rendered using a render function in setup()'),
            h('button',{onClick:()=>alert('button clicked!')},'点我')
        ])
    }
}).component('scu4',scu4)


app.config.globalProperties.$axios=axios

app.provide('$axios',axios)

// app.use(createPinia())
app.use(pinia)
app.use(router)
// app.use(setupPermission)

app.mount('#app')
